export default function settle(resolve, reject, response) {
  const validateStatus = response.config.validateStatus;
  console.log('检验状态码,你即将使用的验证函数为：' + validateStatus.toString());
  if (!response.status || !validateStatus || validateStatus(response.status)) {
    resolve(response);
  } else {
    reject(`Request failed with status code:${response.status}`);
  }
}
